package com.yuju.order.enums;
public enum CertificateTypeEnum {
	 	SANKE((byte)1,"身份证"),
	    LOCAL((byte)2, "港澳通行证"),
		CENTRAL((byte)3,"护照"),
		WE_CHART((byte)4, "军官证"),
		OFFICAL_WEB((byte)5, "其他证件");
	    private byte value;
	    private String name;

	    CertificateTypeEnum(byte value, String name) {
	        this.name = name;
	        this.value = value;
	    }

	    public String getName() {
	        return name;
	    }

	    public byte getValue() {
	        return value;
	    }
	    public  static String getNameByValue(byte value){
	    	for(CertificateTypeEnum e : CertificateTypeEnum.values()){
	    		if(e.getValue()== value){
	    			return e.getName();
	    		}
	    	}
			return "未知枚举";
	    }
	    
}
